From 5b43e1bd6c2bc9f5fee360af3812383386b4de46 Mon Sep 17 00:00:00 2001 From: Miles Bader Date: Wed, 18 Sep 2002 02:35:50 +0000 Subject: [PATCH] (diff-mode): Don't evaluate `compilation-last-buffer' unless it's bound. --- lisp/diff-mode.el | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/lisp/diff-mode.el b/lisp/diff-mode.el index b04719298a8..94ce53c1040 100644 --- a/lisp/diff-mode.el +++ b/lisp/diff-mode.el @@ -1,6 +1,6 @@ ;;; diff-mode.el --- a mode for viewing/editing context diffs -;; Copyright (C) 1998, 1999, 2000, 2001 Free Software Foundation, Inc. +;; Copyright (C) 1998, 1999, 2000, 2001, 2002 Free Software Foundation, Inc. ;; Author: Stefan Monnier ;; Keywords: convenience patch diff @@ -889,7 +889,9 @@ a diff with \\[diff-reverse-direction]." (substring buffer-file-name 0 (match-beginning 0)))) ;; Be careful not to change compilation-last-buffer when we're just ;; doing a C-x v = (for example). - (let ((compilation-last-buffer compilation-last-buffer)) + (let ((compilation-last-buffer + (and (boundp 'compilation-last-buffer) + compilation-last-buffer))) (compilation-shell-minor-mode 1)) (when (and (> (point-max) (point-min)) diff-default-read-only) -- 2.30.2